package com.zz.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.TaskScheduler;
import org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler;

@Configuration
public class HeartbeatConfig {
    @Bean
    public TaskScheduler heartBeatScheduler(){
        // 创建心跳任务调度器
        return new ThreadPoolTaskScheduler();
    }
}

